﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="finance_settlement_past.aspx.cs" Inherits="SF.Ucenter.admin.finance.finance_settlement_past" %>
<%@ Import Namespace="SF.Common" %>

<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,initial-scale=1.0,user-scalable=no" />
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <title>财务结算记录</title>
    <link href="../../scripts/artdialog/ui-dialog.css" rel="stylesheet" type="text/css" />
    <link href="../skin/default/style.css" rel="stylesheet" type="text/css" />
    <link href="../../css/pagination.css" rel="stylesheet" type="text/css" />
    <link href="../../css/validate.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="../../scripts/jquery/jquery-1.11.2.min.js"></script>
    <script type="text/javascript" charset="utf-8" src="../../scripts/datepicker/WdatePicker.js"></script>
    <script type="text/javascript" src="../../scripts/artdialog/dialog-plus-min.js"></script>
    <script type="text/javascript" charset="utf-8" src="../js/laymain.js"></script>
    <script type="text/javascript" charset="utf-8" src="../js/common.js"></script> 
    <style type="text/css">
        .date-input {
            width:130px;
        }
    </style>
    <script type="text/javascript">
        //财务结算打印订单
        function settlePrint(settleNum) {
            var winDialog = top.dialog({
                title: '打印订单',
                url: 'finance/settlement_dialog_print.aspx?settleNum='+settleNum,
                width: 850
            }).showModal();
        }
    </script>
</head>

<body class="mainbody">
    <form id="form1" runat="server">
        <asp:HiddenField ID="hdid" Value="0" runat="server" />
        <!--导航栏-->
        <div class="location"> 
            <a href="../center.aspx" class="home"><i></i><span>首页</span></a>
            <i class="arrow"></i>
            <span>财务结算记录</span>
        </div>
        <!--/导航栏--> 
        <!--工具栏-->
        <div id="floatHead" class="toolbar-wrap">
            <div class="toolbar">
                <div class="box-wrap">
                  <a class="menu-btn"></a>
                  <div class="l-list">
                    <ul class="icon-list">
                        <li><a class="move" target="_blank" href="finance_settlement_past.aspx?action=export&state=<%=state %>&keywords=<%=keywords %>"><i></i><span>导出</span></a></li>
                    </ul>
                    <div class="menu-list">
                      <div class="rule-single-select">
                        <asp:DropDownList ID="ddlStatus" runat="server" AutoPostBack="True" onselectedindexchanged="ddlStatus_SelectedIndexChanged">
                          <asp:ListItem Value="-1" Selected="True">所有结算单</asp:ListItem>
                          <asp:ListItem Value="0">未完成收费</asp:ListItem>
                          <asp:ListItem Value="1">已完成收费</asp:ListItem>
                        </asp:DropDownList>
                      </div>
                    </div>
                  </div>
                  <div class="r-list">
                    <asp:TextBox ID="txtKeywords" runat="server" CssClass="keyword" />
                    <asp:LinkButton ID="lbtnSearch" runat="server" CssClass="btn-search" onclick="btnSearch_Click">查询</asp:LinkButton>
                  </div>
                </div>
            </div>
        </div>
        <!--/工具栏-->

        <!--列表-->
        <div class="table-container"> 
            <asp:Repeater ID="rptList" runat="server">
                <HeaderTemplate>
                <table width="100%" border="0" cellspacing="0" cellpadding="0" class="ltable">
                    <tr>                       
                        <th align="center" width="16%">结算单号</th>
                        <th align="left" width="16%">经手人</th>
                        <th align="left" width="13%">合计</th>
                        <th align="left" width="15%">已收</th>
                        <th align="left" width="8%">未收</th>
                        <th align="left" width="12%">状态</th>
                        <th align="left" width="12%">生成时间</th>
                        <th width="10%">操作</th>
                    </tr>
                    <tbody class="ltbody">

                </HeaderTemplate>
                <ItemTemplate>
                    <tr>                    
                    <td align="center">
                        <asp:HiddenField ID="hidId" runat="server" Value='<%#Eval("id")%>' />
                        <%#Eval("settlement_num") %>
                    </td>
                    <td align="left"><%#Eval("user_name")%></td>
                    <td align="left"><span style="color:blue"><%#Eval("total_amount")%></span></td>
                    <td align="left"><span style="color:green"><%#Eval("received")%></span></td>
                    <td align="left"><span style="color:red"><%#Eval("not_received")%></span></td>
                    <td align="left"><span title="<%# Eval("state").ToString() == "1" ?"已完成收费":"未完成收费" %>" class="<%# Eval("state").ToString() == "1" ?"Validform_right":"Validform_wrong" %>"></span></td>
                    <td align="left"><%#Eval("create_time") %></td>
                    <td align="center"><a href="business_settlement.aspx?settleNum=<%#Eval("settlement_num")%>">查看</a>
                        |&nbsp;<a href="javascript:settlePrint('<%#Eval("settlement_num")%>');">打印</a></td>
                </tr>

                </ItemTemplate>
                <FooterTemplate>
                        <%#rptList.Items.Count == 0 ? "<tr><td align=\"center\" colspan=\"8\">暂无记录</td></tr>" : ""%>
                    </tbody>
                    </table>
                </FooterTemplate>
            </asp:Repeater>            
        </div>
        <!--/列表-->

        <!--内容底部-->
        <div class="line10"></div>
        <div class="pagelist" style="margin-top:10px;">
            <div class="l-btns">
                <span>显示</span><asp:TextBox ID="txtPageNum" runat="server" CssClass="pagenum" onkeydown="return checkNumber(event);"
                    OnTextChanged="txtPageNum_TextChanged" AutoPostBack="True"></asp:TextBox><span>条/页</span>
            </div>
            <div id="PageContent" runat="server" class="default"></div>
        </div>      
        <!--/内容底部-->
    </form>
</body>
</html>

